<?php $this->load->view('common/dpc-head');?>
<?php $this->load->view('common/dpc-header');?>
<h1 id="all-promo-codes-title" class="text-center" style="color:#F45435;text-shadow:2px 2px 2px #51245F;font-weight:400;">Browse Stores A - Z</h1>
<?php $this->load->view('common/dpc-top-search');?>
<div role="main">
            
            <div class="stripe-regular">
              <div class="row">
                
                <div id="all-promo-codes" class="large-9 columns">
                                    
                  <div class="coupons-wrapper">
                    <div class="row">
                      <div class="large-8 columns">
                        <h2 id="browse-a-z-title">
                        	<div style="float:left;"><img src="/public/images/browse-by.png" style="border-radius:4px;box-shadow:0 0 4px #A049BB;" /></div>
                        	<div style="float:left;margin:20px 0 0 15px;font-size:22px;">Browse Stores A - Z</div>
                        	<div style="clear:both;"></div>
                        </h2>
                      </div>
                    </div>
                    <section id="all-promo-codes-box" class="company-box" style="margin-top:0;">
	                <div class="row">
	                  <div class="column">
	                    <div class="wrapper-3 tertiary">
	                      <div class="row collapse" style="padding:15px 10px;line-height:28px;text-align:justify;font-size:14px;">
	                        <div id="browse-a-z" class="a-z">
								<ul>
							    	<li><a href="/all-promo-codes/0-9">0-9</a></li>
							        <?php for($a=65;$a<=90;$a++){ ?>
										<li><a href="/all-promo-codes/<?php echo chr($a);?>"><?php echo chr($a);?></a></li>
									<?php }?>
								</ul>
							</div>
							<div style="clear:both;"></div>
							<?php $oldStoreName=""; for($i=0;$i<count($allStoresArray);$i++){ ?>
							<?php if($oldStoreName!=substr($allStoresArray[$i]['store_name'], 0, 1)){ ?>
							<div class="alphaStores">
								<h4><?php echo substr($allStoresArray[$i]['store_name'], 0, 1); ?></h4>
								<ul><?php } ?>
									<li><a href="/<?php echo $allStoresArray[$i]['store_url']; ?>-promo-codes"><?php echo $allStoresArray[$i]['store_name'].'  ('.$allStoresArray[$i]['noOfCoupons'].')'; ?></a></li>
									<?php if(isset($allStoresArray[$i+1]['store_name']) && substr($allStoresArray[$i+1]['store_name'], 0, 1)!=substr($allStoresArray[$i]['store_name'], 0, 1)){ ?>
								</ul>
								<div style="clear:both;"></div>
							</div>
							<?php } ?>
							<?php $oldStoreName=substr($allStoresArray[$i]['store_name'], 0, 1); } ?><div style="clear:both;"></div>
	                      </div>
	                    </div>
	                  </div>
	                </div>
	                </section>
                    
                  </div>
                  
                </div>

                <aside class="large-3 columns main-sidebar bg">
                  <?php if(isset($bannersArray) && !empty($bannersArray)){?>
                  <div id="banner" class="video-box small" style="margin:0px 0 10px 0;">
                    <a href="<?php echo $bannersArray[0]['banner_link'];?>" target="_blank" rel="nofollow"><img src="<?php echo $bannersArray[0]['banner_image'];?>" alt="<?php echo $bannersArray[0]['banner_alt'];?>" border="0" /></a>
                  </div>
                  <?php }?>
                  
                  <div class="testimonials-box flexslider" style="margin:0;">
                    <ul class="rr">
                      <li>
                        <div class="testimonial">
                          <div class="wrapper-5" id="catTag">
                          	<h3>Related Categories</h3>
                          	<ul id="related-categories">
                          	<?php foreach($relatedCat as $other){?>
                          		<li>
                          			<a href="/<?php echo $other['parent_url'].'/'.$other['category_url'];?>"><?php echo $other['category_name'];?></a>
                          		</li>
                          	<?php }?>
                          	<div style="clear: both;"></div>
                          	</ul>
                          </div>
                        </div>
                      </li>
                    </ul>
                  </div>
                
                </aside>

              </div>
            </div>
            
          </div>
<?php $this->load->view('common/dpc-footer');?>